﻿using SocketTcpServer.Enum;

using RpcHelper;

namespace SocketTcpServer.Model
{
    internal class PageDetailed
    {
        public PageDetailed(SyntonySet returnSet,Page page)
        {
            this.Status = PageStatus.等待发送;
            this.SyntonySet = returnSet;
            this.PageType = page.PageType;
            this.TimeOut = HeartbeatTimeHelper.HeartbeatTime + Config.SocketConfig.SyncTimeOut;
        }
        public PageType PageType;

        public byte[] ReturnData;
        public IOSendInterface.SendType DataType;
        public bool IsError;
        /// <summary>
        /// 错误信息
        /// </summary>
        public string Error;

        /// <summary>
        /// 最后更新时间
        /// </summary>
        public int TimeOut;

        /// <summary>
        /// 包的状态
        /// </summary>
        public volatile PageStatus Status;

        /// <summary>
        /// 回调设置
        /// </summary>
        public SyntonySet SyntonySet;
    }
}
